﻿function sendcode(id)
{
  disabledbtn = $(id);
  $(id).attr("disabled","disabled");
  $(id).parent().find(".tipspan").show();
  numtime = 60;
  $(id).val("重新发送("+numtime+"秒)");
  //setTimeout(function(){$(disabledbtn).attr("disabled","");},30000);
  timebtn = setInterval(function(){numtime --; if(numtime == 0){clearTimeout(timebtn);$(id).attr("disabled","");$(disabledbtn).val("重新发送");return;} $(disabledbtn).val("重新发送("+numtime+"秒)");},100);
}
var numtime = 60;
var disabledbtn;
var timebtn;

function sendcode_other(id)
{
  disabledbtn_other = $(id);
  $(id).attr("disabled","disabled");
  $(id).parent().find(".tipspan").show();
  numtime_other = 60;
  $(id).val("重新发送("+numtime_other+"秒)");
  //setTimeout(function(){$(disabledbtn).attr("disabled","");},30000);
  timebtn_other = setInterval(function(){numtime_other --; if(numtime_other == 0){clearTimeout(timebtn_other);$(id).attr("disabled","");$(disabledbtn_other).val("重新发送");return;} $(disabledbtn_other).val("重新发送("+numtime_other+"秒)");},100);
}
var numtime_other = 60;
var disabledbtn_other;
var timebtn_other;